/**
 * @description Cookie操作
 */
const Cookie = require('js-cookie')
export default {
  /**
   * @description 设置Cookie
   * @param name
   * @param value
   * @param time
   */
  set (name, value, time = 30) {
    Cookie.set(name, value, {
      expires: time
    })
  },
  /**
   * @description 获取Cookie
   * @param name
   * @return {*}
   */
  get (name) {
    return Cookie.get(name)
  },
  /**
   * @description 删除Cookie
   * @param name
   */
  delete (name) {
    Cookie.remove(name)
  }
}
